<template>
  <div>
    <button @click="handleClick">
      <slot>默认按钮</slot>
    </button>
  </div>
</template>

<script>
export default {
  props: ["disbaled"],
  methods: {
    handleClick() {
      if (this.disbaled) return;
      this.$emit("click");
    }
  }
};
</script>
